// apis/user.js
// 引入网络请求模块
import { uniFetch } from './uni-fetch'
export default {
  // 初始化
	initInventoryPackageOrder(data){
		return uniFetch.post('/api/inventoryPackage/initInventoryPackageOrder',data)
	},
	// 订购
	processInventoryPackageOrder(data){
		return uniFetch.post('/api/inventoryPackage/processInventoryPackageOrder',data)
	},
	// 获取电话号码归属地
	ipPhone(data){
		return uniFetch.get(`/api/ispArea/query/${data.phone}`)
	},
	// 用户退出登录
	authLogout(){
		return uniFetch.get(`/api/app/auth/logout`)
	},
	// 初始化 支付宝审核版本
	mpVersionCurrent(data){
		return uniFetch.get(`/api/mp/version/current`)
	},
	// 获取用户token
	userLogin(data){
		return uniFetch.post('/api/wechat/mp/user/authorizeUserInfo',data)
	},
	//APP使用联合会员-订单权益明细数据表 操作-API
	getReceiveEquity(data){
		return uniFetch.post('/api/am/orderEquityDetail/receiveEquity',data)
	},
	//APP使用联合会员-订单权益明细数据表 信息查询-API
	getReceiveEquityPage(data){
		return uniFetch.post('/api/am/orderEquityDetail/page',data)
	},
	// 获取用户手机号
	getUserInfo(){
		return uniFetch.post('/api/appUser/my')
	},
	//会员领取
	getTclGrantEquity(data){
		return uniFetch.post('/api/associateMember/equity/command/tcl/grantEquity',data)
	},
	// APP使用联合会员-订单支付信息查询-API
	getPaymentInfoPage(data){
		return uniFetch.post('/api/am/order/paymentInfo/page',data)
	},
	//APP使用联合会员-订单信息查询-API
	getOrderPage(data){
		return uniFetch.post('/api/am/order/page',data)
	},
	//微信小程序登录
	getWXLogin(data){
		return uniFetch.post('/api/wechat/ma/user/login',data)
	},
	//支付宝小程序登录
	getApplyLogin(data){
		return uniFetch.post('/api/alipay/ma/user/login',data)
	},
	// 支付宝小程序
	getApllyAuth(data){
		return uniFetch.post('/api/alipay/ma/user/authorizeMobile',data)
	},
	// 微信小程序授权并保存手机号码
	getWXAuthor(data){
		return uniFetch.post('/api/wechat/ma/user/authorizeMobile',data)
	},
	// 联合会员订单(签约)操作-API
	associateMemberSign(data){
		return uniFetch.post('/api/associateMember/command/signOrder',data)
	},
	// 产品统计指标数据操作-API
	indicatorsRecordPageViewsPost(data){
		return uniFetch.post('/api/product/statistical/indicators/recordPageViews',data)
	},
	// 联合会员发短信
	authSendSms(data){
		return uniFetch.post('/api/app/auth/sendSms',data)
	},
	// 联合会员登录
	authRegisterAndLogin(data){
		return uniFetch.post('/api/app/auth/registerAndLogin',data)
	},
	
	// 联合会员-外部权益查询-API
	equityReceiveQueryPage(data){
		return uniFetch.post('/api/am/external/equity/receive/query/page',data)
	},
	
	// 联合会员-外部权益领取-API
	receiveCommandReceiveEquity(data){
		return uniFetch.post('/api/am/external/equity/receive/command/receiveEquity',data)
	},
}
